Notions of Aliasing and Ownership

نویسندگان

  • Alan Mycroft
  • Janina Voigt
چکیده

We survey notions of aliasing and ownership. An extreme but conceptually useful model is that of pure linear languages where each object is constructed once and read, being consumed, once. We see more realistic programming languages as relaxing this to allow multiple references to an object (spatial aliasing) or multiple sequenced operations on a single live reference (temporal aliasing) before the object is deallocated. Concurrency complicates things (concurrent aliasing) because spatial aliasing may only happen under certain scheduling conditions. We argue that this view of aliasing is closely related to that of type tags in low-level implementations of dynamic types. Similarly, we argue that ownership corresponds to a higher-level structured view of the net of objects and references, analogous to higher-level types in programming languages. In the same way that not all highlevel data-structure consistency requirements can be captured by existing practical syntactic type forms, not all aliasing requirements can be captured by existing syntactic forms of aliasing control (uniqueness, owners-as-dominators, owners-as-modifiers and static capabilities), each of which is successful in a limited domain. We conclude by arguing for a more holistic approach to the topic of aliasing and ownership.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Ownership Domains: Separating Aliasing Policy from Mechanism

Ownership types promise to provide a practical mechanism for enforcing stronger encapsulation by controlling aliasing in objectoriented languages. However, previous ownership type proposals have tied the aliasing policy of a system to the mechanism of ownership. As a result, these proposals are too weak to express many important aliasing constraints, yet also so restrictive that they prohibit m...

متن کامل

Using ownership types to support library aliasing boundaries

This paper describes a library for concurrency used in a 10developer videogame project. The developers were inexperienced, yet there were no problems with data races in the multi-threaded application. We credit this to the explicit representation of ownership in the design of the library. Correct library usage implies aliasing boundaries which bear a strong resemblance to the ownersas-dominator...

متن کامل

Object Ownership in Program Verification

Dealing with aliasing is one of the key challenges for the verification of imperative programs. For instance, aliases make it difficult to determine which abstractions are potentially affected by a heap update and to determine which locks need to be acquired to avoid data races. Object ownership was one of the first approaches that allowed programmers to control aliasing and to restrict the ope...

متن کامل

Featherweight Generic Ownership

Object ownership is an approach to controlling aliasing in programming languages. Proposals for adding ownership to programming languages do not directly support type genericity. We present Featherweight Generic Ownership — the first system to unify ownership and type polymorphism. Our type system extends Featherweight Generic Java with locations to support ownership and confinement invariants,...

متن کامل

Generic Ownership: Practical Alias Control in Object-Oriented Programming Languages

Modern object-oriented languages support many techniques that simplify the work of a programmer. Among them is type genericity — an ability to create generic descriptions of algorithms and object structures that will be automatically specialised by supplying type information at run time. On the other hand, object-oriented technologies still suffer from bad effects of aliasing— a case of many ob...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2013